import { pubRequire } from '@utils/public'
const baseUrl = '/banned-user'
//获取列表
export function getSearchList(params, callBack, errBack) {
  return pubRequire('get', baseUrl, params, callBack, errBack)
}

//禁言用户
export function bannedUser(params, callBack, errBack) {
  return pubRequire('put', `${baseUrl}/banned`, params, callBack, errBack)
}

//解除禁言
export function dissemination(dpAccount, callBack, errBack) {
  return pubRequire(
    'put',
    `${baseUrl}/lift-ban/${dpAccount}`,
    '',
    callBack,
    errBack
  )
}

//禁言历史
export function bannedhistoryList(dpAccount, callBack, errBack) {
  return pubRequire(
    'get',
    `${baseUrl}/records/${dpAccount}`,
    '',
    callBack,
    errBack
  )
}
